<?php 
require_once($_SERVER['DOCUMENT_ROOT']."/defaultconf.mex");
MYDCONN();
$GLOBALS['MYT']=$GLOBALS['MYD'];
	if (!isset($_POST['CODE'])){$_POST['CODE']=0;}
	if (!isset($_POST['Office'])){$_POST['Office']=0;}
	 mn_field('select','ED','Office',$_POST['Office'],"SELECT ref AS ID, name AS NAME
	  			FROM main_offices
				WHERE Type IN (1,2,5)
				ORDER BY name ASC",'','','" onchange="
	document.edtCdcInvoice.action=\'Modules/CentrodeCustos/Lib/sel_staff.php\';
	subform(\'edtCdcInvoice\',\'UserDiv\');');